<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html 	xmlns="http://www.w3.org/1999/xhtml"
    	xmlns:ui="http://java.sun.com/jsf/facelets"
    	xmlns:f="http://java.sun.com/jsf/core"
    	xmlns:h="http://java.sun.com/jsf/html"
    	xmlns:p="http://primefaces.org/ui"
    	xmlns:s="http://www.suricattus.com.br/jsf/ui"
		xmlns:sf="http://www.suricattus.com.br/jsf/fn"
    	xmlns:composite="http://java.sun.com/jsf/composite">

	<composite:interface>	
	
		<composite:attribute name="seguro" required="true"  />
		
		<composite:attribute name="servico" required="true"  />
		
		<composite:attribute name="showDescricao" required="true"  />
		
		<composite:attribute name="showRestricoes" required="true"  />
		
		<composite:attribute name="showCoberturas" required="true"  />
		
		<composite:attribute name="showCondicoesGerais" required="true"  />
		
		<composite:attribute name="controller" required="true"  />
    	
	</composite:interface>	
	
	<composite:implementation>	
	
		<div class="row-fluid">
		
			<div class="span10 offset1"> 
				<div>
					<table width="100%">
						<tr>
							<h:panelGroup rendered="#{cc.attrs.servico.fornecedor ne null and cc.attrs.servico.fornecedor.imagem ne null and cc.attrs.servico.fornecedor.imagem.link ne null}">
								<td width="80px">
									<div>
										<img src="#{cc.attrs.servico.fornecedor.imagem.link}" width="55px" height="55px" style="top: -7px;position: relative;left: 10px;" />
									</div>
								</td>
							</h:panelGroup>
							<td>
								<div>
									<div class="top">
										<div style="text-align: center; float:right;">
											<h:form style="margin: 0px;">
												<h:link styleClass="btn btn-primary" onclick="_dgInfoDescricao.show()" process="@this" rendered="#{cc.attrs.showDescricao}">
													<h:outputText value="#{labels['label.descricao']}" />
													<i class="icon-zoom-in icon-white" />
												</h:link>
												
												<p:spacer width="10"/> 
											
												<h:link styleClass="btn btn-primary btn-danger" onclick="_dgInfoRestricoes.show()" process="@this" rendered="#{cc.attrs.showRestricoes}">
													<h:outputText value="#{labels['label.restricoes']}" />
													<i class="icon-zoom-in icon-white" />
												</h:link>
							
												<p:spacer width="10"/> 
											
												<h:link styleClass="btn btn-primary btn-success" onclick="_dgInfoCoberturas.show()" process="@this" rendered="#{cc.attrs.showCoberturas}">
													<h:outputText value="#{labels['label.coberturas']}" />
													<i class="icon-zoom-in icon-white" />
												</h:link> 
							
												<p:spacer width="10"/> 
												<h:commandLink global="false" styleClass="btn btn-primary btn-success" process="@form" actionListener="#{cc.attrs.controller.visualizarCondicoesGerais}" 
														immediate="true" ajax="false" rendered="#{cc.attrs.controller.arquivo ne null and cc.attrs.showCondicoesGerais}">
													<h:outputText value="#{labels['label.condicoes.gerais']}" />
													<i class="icon-zoom-in icon-white" />
												</h:commandLink>
											</h:form>
										</div>
										<div>
											<p class="titulo"> 
												<span>
													<h:outputText value="#{cc.attrs.servico.titulo}" />
												</span>
											</p>
										</div>
										<div>
											<p>
												<h:link outcome="pretty:home" > 
													<h:outputText value="#{labels['label.inicio']}" />
												</h:link>
												<h:panelGroup rendered="#{cc.attrs.servico.grupoProduto.grupoPai ne null}">
						                              	&gt;&gt;
						                            <h:link outcome="pretty:detalharGrupo">
														<f:param name="id" value="#{cc.attrs.servico.grupoProduto.grupoPai.id}" />
														<h:outputText value="#{cc.attrs.servico.grupoProduto.grupoPai.titulo}" />
													</h:link>
						                        </h:panelGroup>
						                           	 	&gt;&gt;
						                        <h:link outcome="pretty:detalharGrupo">
						                        	<f:param name="id" value="#{cc.attrs.servico.grupoProduto.id}" />
						                    	 	<h:outputText value="#{cc.attrs.servico.grupoProduto.titulo}" />
						                    	</h:link>
											</p>
											<hr/>
										</div>
									</div>
								</div>
							</td>
						</tr>
					</table>
				</div>
			</div>
		</div>
		
		<div class="clear" />
	</composite:implementation>
	
</html>